package com.lanluo.service.concurrent.threadpool;

/**
 * @author
 * @date 2018-08-28-13:55
 */
public class MyTask implements Runnable{

    private int tasknum;

    public MyTask(int tasknum) {
        this.tasknum = tasknum;
    }

    public void run() {
        System.out.println("正在执行task------------------------------------------ "+tasknum);
        try {
            Thread.currentThread().sleep(4000);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        System.out.println("task "+tasknum+"执行完毕");
    }
}